﻿<!-- HEADER -->
<div>

    <nav class="top-bar" style="margin-bottom:0">
      <ul class="title-area">
        <!-- Title Area -->
        <li class="name">
          <h1><a href="#">Top Bar Title </a></h1>
        </li>
        <!-- Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone -->
        <li class="toggle-topbar menu-icon"><a href="#"><span>Menu</span></a></li>
      </ul>

      <section class="top-bar-section">
        <!-- Left Nav Section -->
        <ul class="left">
          <li class="divider"></li>
          <li class="active"><a href="#">Main Item 1</a></li>
          <li class="divider"></li>
          <li><a href="#">Main Item 2</a></li>
          <li class="divider"></li>
          <li class="has-dropdown"><a href="#">Main Item 3</a>

            <ul class="dropdown">
              <li class="has-dropdown"><a href="#">Dropdown Level 1a</a>

                <ul class="dropdown">
                  <li><label>Dropdown Level 2 Label</label></li>
                  <li><a href="#">Dropdown Level 2a</a></li>
                  <li><a href="#">Dropdown Level 2b</a></li>
                  <li class="has-dropdown"><a href="#">Dropdown Level 2c</a>

                    <ul class="dropdown">
                      <li><label>Dropdown Level 3 Label</label></li>
                      <li><a href="#">Dropdown Level 3a</a></li>
                      <li><a href="#">Dropdown Level 3b</a></li>
                      <li class="divider"></li>
                      <li><a href="#">Dropdown Level 3c</a></li>
                    </ul>
                  </li>
                  <li><a href="#">Dropdown Level 2d</a></li>
                  <li><a href="#">Dropdown Level 2e</a></li>
                  <li><a href="#">Dropdown Level 2f</a></li>
                </ul>
              </li>
              <li><a href="#">Dropdown Level 1b</a></li>
              <li><a href="#">Dropdown Level 1c</a></li>
              <li class="divider"></li>
              <li><a href="#">Dropdown Level 1d</a></li>
              <li><a href="#">Dropdown Level 1e</a></li>
              <li><a href="#">Dropdown Level 1f</a></li>
              <li class="divider"></li>
              <li><a href="#">See all &rarr;</a></li>
            </ul>
          </li>
          <li class="divider"></li>
        </ul>

        <!-- Right Nav Section -->
        <ul class="right">
          <li class="divider hide-for-small"></li>
          <li class="has-dropdown"><a href="#">Main Item 4</a>

            <ul class="dropdown">
              <li><label>Dropdown Level 1 Label</label></li>
              <li class="has-dropdown"><a href="#" class="">Dropdown Level 1a</a>

                <ul class="dropdown">
                  <li><a href="#">Dropdown Level 2a</a></li>
                  <li><a href="#">Dropdown Level 2b</a></li>
                  <li class="has-dropdown"><a href="#">Dropdown Level 2c</a>

                    <ul class="dropdown">
                      <li><a href="#">Dropdown Level 3a</a></li>
                      <li><a href="#">Dropdown Level 3b</a></li>
                      <li><a href="#">Dropdown Level 3c</a></li>
                    </ul>
                  </li>
                  <li><a href="#">Dropdown Level 2d</a></li>
                  <li><a href="#">Dropdown Level 2e</a></li>
                  <li><a href="#">Dropdown Level 2f</a></li>
                </ul>
              </li>
              <li><a href="#">Dropdown Level 1b</a></li>
              <li><a href="#">Dropdown Level 1c</a></li>
              <li class="divider"></li>
              <li><label>Dropdown Level 1 Label</label></li>
              <li><a href="#">Dropdown Level 1d</a></li>
              <li><a href="#">Dropdown Level 1e</a></li>
              <li><a href="#">Dropdown Level 1f</a></li>
              <li class="divider"></li>
              <li><a href="#">See all &rarr;</a></li>
            </ul>
          </li>
          <li class="divider"></li>
          <li class="divider show-for-small"></li>
          <li class="has-form">
            <a class="button" href="#">Button!</a>
          </li>
        </ul>
      </section>
    </nav>

    <nav class="top-bar search-bar" style="padding-bottom:4em">
      <ul class="title-area">
        <!-- Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone -->
        <li class="toggle-topbar"><a href="#"><span></span></a></li>
      </ul>

      <section class="top-bar-section">
    
        <!-- Right Nav Section -->
        <ul class="right">

          <li class="has-form">
            <form>
              <div class="row collapse">
                <div class="small-8 columns">
                  <input type="text">
                </div>
                <div class="small-4 columns">
                  <a href="#" class="alert button">Search</a>
                </div>
              </div>
            </form>
          </li>
        </ul>
      </section>
    </nav>

</div>

<!-- CONTENT -->
<div>

    <div class="row">
	    <div class="large-12 columns">
		    <h2 style="margin-top:0; margin-bottom:0">Welcome to our site</h2>
		    <p>It has a responsive view.</p>
		    <hr />
	    </div>
    </div>

    <div ng-controller="ProductsController">

        <div class="row">

            <!-- PRODUCTS -->
	        <div class="large-9 columns">
		        <h3>Products</h3>

                <!-- Filter and Sort products -->
                <div class="row">

                    <div class="large-6 columns">
                        <dl class="sub-nav">
                            <dt>Filter:</dt>
                            <dd
                                ng-class="{active: filterExp==null}"
                                ng-click="setFilter(null)"
                                >
                                <a href="#">All</a>
                            </dd>
                            <dd
                                ng-class="{active: filterExp=='non-del'}"
                                ng-click="setFilter('non-del')"
                                >
                                <a href="#">Non-Deleted</a>
                            </dd>
                        </dl>
                    </div>

                    <div class="large-6 columns">
                        <dl class="sub-nav">
                            <dt>Sort:</dt>
                            <dd
                                ng-class="{active: predicate==null}"
                                ng-click="sort(null)"
                                >
                                <a href="#">Unsorted</a>

                            </dd>
                            <dd
                                ng-class="{active: predicate=='Name', reversed: (predicate=='Name' && reverse)}"
                                ng-click="sort('Name')"
                                ><a href="#">By Name</a>
                            </dd>
                            <dd
                                ng-class="{active: predicate=='Date', reversed: (predicate=='Date' && reverse)}"
                                ng-click="sort('Date')"
                                ><a href="#">By Date</a>
                            </dd>
                        </dl>
                    </div>

                </div>

                <!-- Products header -->
                <div class="panel transparent-panel hide-for-small">
                    <div class="row">
                        <div class="small-2 large-1 columns">
                            <strong>Icon</strong>
			            </div>
			            <div class="small-4 large-4 columns">
                            <strong>Name</strong>
			            </div>
			            <div class="large-3 columns">
                            <strong>Date</strong>
			            </div>
                        <div class="large-4 columns">
                            <strong>Description</strong>
                        </div>
                    </div>
                </div>

                <!-- Products list -->
                <div class="panel" ng-repeat="product in Products | orderBy:predicate:reverse | filter:filterFunc">
		            <div class="row">
			            <div class="small-4 large-1 columns">
                            <img src="/Content/demo/ok-256x2561.png" width="32" height="32" />
			            </div>
			            <div class="small-4 large-4 columns zero-padding-left">
                            {{product.Name}}
			            </div>
			            <div class="large-3 columns">
                            <div class="small-4 columns show-for-small zero-padding-left">Date:&nbsp;</div>{{product.Date | date: dateFormat}}
			            </div>
                        <div class="large-4 columns">
                            <div class="small-4 columns show-for-small zero-padding-left">Description:&nbsp;</div>{{product.Description}}
                        </div>
		            </div>
                    <div class="row">
                        <div class="large-offset-8 columns">
                            <ul class="button-group">
                                <li><a ng-click="edit(product)" class="small round button" href="#">Edit</a></li>
                                <li><a ng-click="deleteItem(product)" class="small round alert button" ng-show="canDelete(product.State)" href="#">Delete</a></li>
                                <li><a ng-click="undeleteItem(product)" class="small round alert button" ng-show="!canDelete(product.State)" href="#">Undelete</a></li>
                            </ul>
                        </div>
                    </div>
                </div>

	        </div>

            <!-- SIDE STUFF -->
            <div class="large-3 columns">
                <h3>Side stuff goes here</h3>
                <ul>
                    <li>Item 1</li>
                    <li>Item 2</li>
                    <li>Item 3</li>
                </ul>
            </div>

        </div>

        <!-- Edit -->
        <div class="alert-box footer" ng-show="isEditOpen">
            <a href="#" class="close" ng-click="cancelEdit()">&times;</a>
            <div class="row">
		        <div class="small-6 large-4 columns">
                    <label>Name: </label>
			        <input type="text" placeholder="Name" ng-model="productToEdit.Name" />
                </div>
                <div class="small-6 large-4 columns">
                    <label>Date: </label>
			        <input type="date" placeholder="yyyy-MM-dd" ng-model="productToEdit.DateOnly" />
                </div>
                <div class="large-4 columns">
                    <label>Description: </label>
			        <input type="text" placeholder="Description" ng-model="productToEdit.Description" />
                </div>
            </div>
            <div class="row">
                <div class="large-12 columns">
                    <ul class="button-group even-4">
                        <li><a href="#" class="button success prefix" ng-click="addNew()">Add</a></li>
                        <li><a href="#" class="button success prefix" ng-click="completeEdit()">Change</a></li>
                        <li><a href="#" class="button success prefix" ng-click="clearEdit()">Clear</a></li>
                        <li><a href="#" class="button success prefix" ng-click="synch()">Sync</a></li>
                    </ul>
                </div>
	        </div>
        </div>

</div>
